Skip to content

improvement(search): fall back to Jira summaries holding half the terms of a longer query - #9115

Merged
waleedlatif1 merged 3 commits into
stagingfrom
improvement/jira-summary-half
Oct 16, 2026
Merged

waleedlatif1 merged 3 commits into
stagingfrom
improvement/jira-summary-half

Conversation

@waleedlatif1

@waleedlatif1 waleedlatif1 commented Oct 16, 2026 •

Copy link
Copy Markdown
Collaborator

Summary

  • Follow-up to improvement(search): lead an overflowing Jira all-terms match with issues whose summary holds every term #9111: when an overflowing plain Jira search has no issue whose summary holds every term, and the query has three or more distinct terms, issues whose summary holds at least half of them lead the page instead (the same minimum-should-match rule the any-term Jira filter uses)
  • The all-terms and half-terms summary searches run in parallel, so the extra round adds one Jira round trip, not two; a failure of either keeps whatever the other found, and both failing keeps today's page and cursor
  • Terms are counted the way Jira's stemmed search counts them (a word and its plural once), for both the three-term guard and the filter; two-term queries stay with summaries holding every term (half of two is one word, too loose)
  • The half-term search fetches 50 pair matches before filtering, and orders the survivors by how many terms their summary holds
  • jiraTextClause takes the field (text or summary), replacing the separate summary helper

Type of Change

  • Improvement

Testing

  • atlassian.test.ts: 6 new cases (half-terms summaries lead and a summary below half is dropped, two-term and word-plus-plural queries skip the fallback, most terms first, matches beyond the first pair page, a failed half search keeps the all-terms page and cursor); each guard reverted and its test went red, including cancellation through the parallel searches
  • Offline replay on a large production Jira (read-only), 60 distinct plain queries from real client sessions, blind relevance judge on the pooled issues: 23 overflow a page; with this follow-up the summary-first rule changes 22; 19 better, 3 equal, 1 slightly worse (10 → 9 relevant); relevant issues in the top 10 33 → 103 (all-terms alone, improvement(search): lead an overflowing Jira all-terms match with issues whose summary holds every term #9111: 41 → 60)

Checklist

  • Code follows project style guidelines
  • Self-reviewed my changes
  • Tests added/updated and passing (new tests pass the test-audit authoring gate)
  • No new warnings introduced
  • I confirm that I have read and agree to the terms outlined in the Contributor License Agreement (CLA)

@vercel

vercel Bot commented Oct 16, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

1 Skipped Deployment
Project Deployment Actions Updated
docs Skipped Skipped Oct 16, 2026 5:56am UTC

Request Review

@cubic-dev-ai cubic-dev-ai Bot left a comment •

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

All reported issues were addressed across 3 files

Reply with feedback, questions, or to request a fix.

Turn on auto-fix | Re-trigger cubic

Comment thread apps/sim/lib/sim-search/live/atlassian.ts Outdated
Comment thread apps/sim/lib/sim-search/live/atlassian.ts Outdated
Comment thread apps/sim/lib/sim-search/live/atlassian.ts Outdated
@greptile-apps

greptile-apps Bot commented Oct 16, 2026 •

Copy link
Copy Markdown
Contributor

RetriggerView in GreptileConfidence Score: 5/5

[Medium impact] The PR appears safe to merge; no actionable issues remain from this review.

Summary

Jira searches that overflow a page can now lead with summaries containing at least half the query terms when no summary contains them all.

  • Overflowing Jira searches can lead with summaries holding at least half the words.

Diagram

%%{init: {'theme': 'neutral'}}%%
flowchart TD
  A[Plain Jira search overflows] --> B[Run both summary searches in parallel]
  B --> C{All-term summaries found?}
  C -->|Yes| D[Lead with all-term summaries]
  C -->|No| E{Three distinct terms and qualifying half-term summaries?}
  E -->|Yes| F[Lead with summaries holding the most terms]
  E -->|No| G[Keep original page and cursor]
Loading

Reviews (3) · Last reviewed commit: "improvement(search): share the half-term..." · Reviewed by Greptile

Comment thread apps/sim/lib/sim-search/live/atlassian.ts Outdated
Comment thread apps/sim/lib/sim-search/live/atlassian.test.ts Outdated
@waleedlatif1

Copy link
Copy Markdown
Collaborator Author

@greptile

@waleedlatif1

Copy link
Copy Markdown
Collaborator Author

@cubic-dev-ai review this PR

@cubic-dev-ai

cubic-dev-ai Bot commented Oct 16, 2026

Copy link
Copy Markdown
Contributor

@cubic-dev-ai review this PR

@waleedlatif1 I have started the AI code review. It will take a few minutes to complete.

@cubic-dev-ai cubic-dev-ai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No issues found across 3 files

Confidence score: 5/5

  • Automated review surfaced no issues in the provided summaries.
  • No files require special attention.

Turn on auto-fix | Re-trigger cubic

@waleedlatif1

Copy link
Copy Markdown
Collaborator Author

@greptile

@waleedlatif1

Copy link
Copy Markdown
Collaborator Author

@cubic-dev-ai review this PR

@cubic-dev-ai

cubic-dev-ai Bot commented Oct 16, 2026

Copy link
Copy Markdown
Contributor

@cubic-dev-ai review this PR

@waleedlatif1 I have started the AI code review. It will take a few minutes to complete.

@cubic-dev-ai cubic-dev-ai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No issues found across 3 files

Confidence score: 5/5

  • Automated review surfaced no issues in the provided summaries.
  • No files require special attention.

Turn on auto-fix | Re-trigger cubic

@waleedlatif1
waleedlatif1 merged commit f67d024 into staging Oct 16, 2026
53 checks passed
@waleedlatif1
waleedlatif1 deleted the improvement/jira-summary-half branch October 16, 2026 07:53
waleedlatif1 added a commit that referenced this pull request Oct 16, 2026
* revert(search): restore the v0.9.23 Jira text search

Reverts the Jira summary tiers (#9111, #9115, #9121, #9129). A plain Jira search
again returns the all-terms text match in Jira's order, as in v0.9.23. The
stemmedTerms helper stays; cross-source ranking uses it.

* chore(search): stop exporting stemmedTerms now only text-match uses it

This branch was previously deployed

1 inactive deployment
Preview — 9191e3fd Deployed Oct 16, 2026 by vercel[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant